	MODULE MODA_MSGMEM

#ifndef MAXMSG_H
#define MAXMSG_H
	  USE MODV_MAXMSG
#endif

#ifndef MAXMEM_H
#define MAXMEM_H
	  USE MODV_MAXMEM
#endif

#ifndef MXDXTS_H
#define MXDXTS_H
	  USE MODV_MXDXTS
#endif

#ifndef MXMSGL_H
#define MXMSGL_H
	  USE MODV_MXMSGL
#endif

	  INTEGER :: MUNIT
	  INTEGER :: MLAST
	  INTEGER :: LDXM
	  INTEGER :: NDXM
	  INTEGER :: LDXTS
	  INTEGER :: NDXTS
#ifdef DYNAMIC_ALLOCATION
	  INTEGER :: MXDXM
	  INTEGER :: MXDXW
	  INTEGER, ALLOCATABLE :: MSGP(:)
	  INTEGER, ALLOCATABLE :: MSGS(:)
	  INTEGER, ALLOCATABLE :: MDX(:)
	  INTEGER, ALLOCATABLE :: IPDXM(:)
	  INTEGER, ALLOCATABLE :: IFDXTS(:)
	  INTEGER, ALLOCATABLE :: ICDXTS(:)
	  INTEGER, ALLOCATABLE :: IPMSGS(:)
#else
	  PARAMETER ( MXDXM = MXDXTS*3 )
	  PARAMETER ( MXDXW = MXDXM*MXMSGLD4 )
	  INTEGER :: MSGP(0:MAXMSG)
	  INTEGER :: MSGS(MAXMEM)
	  INTEGER :: MDX(MXDXW)
	  INTEGER :: IPDXM(MXDXM)
	  INTEGER :: IFDXTS(MXDXTS)
	  INTEGER :: ICDXTS(MXDXTS)
	  INTEGER :: IPMSGS(MXDXTS)
#endif

	END MODULE
